﻿namespace HelenServer.UserCenter.Contracts;

public interface IUserService
{
    Task<OperationResult<int>> AddAsync(Operation<UserCreateModel> operation, CancellationToken cancellationToken = default);

    Task<OperationResult<int>> AddRangeAsync(Operation<IEnumerable<UserCreateModel>> operation, CancellationToken cancellationToken = default);

    Task<OperationResult<int>> AddIdentityRangeAsync(Operation<IEnumerable<UserCreateModel>> operation, CancellationToken cancellationToken = default);

    Task<bool> DeleteAsync(Operation<string> operation, CancellationToken cancellationToken = default);

    Task<bool> UpdateAsync(Operation<UserModel> operation, CancellationToken cancellationToken = default);

    Task<UserInfoModel> GetAsync(Operation<string> operation, CancellationToken cancellationToken = default);

    Task<IReadOnlyCollection<UserInfoModel>> GetListAsync(Operation<UserSearchModel> operation, CancellationToken cancellationToken = default);

    Task<bool> ExistsAsync(Operation<string> operation, CancellationToken cancellationToken = default);

    Task<bool> UpdatePasswordAsync(Operation<UserPasswordModel> operation, CancellationToken cancellationToken = default);

    Task<bool> UpdateStatusAsync(Operation<UserStatusModel> operation, CancellationToken cancellationToken = default);
}